import request from '@/utils/request'

//1 - 4级下拉框接口
export function getLv1ToLv4(id) {
  return request({
    url: '/system/ptInfoMonitor/alaDept/selectByParentId/' + id,
    method: 'get'
  })
}

//5级下拉框接口
export function getLv5(id) {
  return request({
    url: '/system/ptInfoMonitor/alaPump/selectByDeptId/' + encodeURIComponent(id),
    method: 'get'
  })
}

//6级下拉框接口
export function getLv6(id) {
  return request({
    url: '/system/ptInfoMonitor/alaDeviceAll/selectByPrentCode/' + encodeURIComponent(id),
    method: 'get'
  })
}

//7级下拉框接口
export function getLv7(id) {
  return request({
    url: '/system/ptInfoMonitor/alaOpeDevice/selectByPrentCode/' + encodeURIComponent(id),
    method: 'get'
  })
}

//8级下拉框接口
export function getLv8(id) {
  return request({
    url: '/system/ptInfoMonitor/alaMoniDataAll/selectByPrentCode/' + encodeURIComponent(id),
    method: 'get'
  })
}
//查询列表接口
export function getTableData(data) {
  return request({
    url: '/system/ptInfoMonitor/alaDept/list',
    method: 'post',
    data
  })
}
//监测点接口
export function getPoint(id) {
  return request({
    url: '/system/ptInfoMonitor/alaMoniDataAll/selectByAltId/' + encodeURIComponent(id),
    method: 'get'
  })
}
